﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using DinhMuc.BUL;
using DinhMuc.Public;
using DinhMuc.UI.crys_report;

namespace DinhMuc.UI.frm_Report
{
    public partial class report_donHang : Form
    {
        public report_donHang()
        {
            InitializeComponent();
        }
        tblQLDonHangBUL qldh = new tblQLDonHangBUL();
        private void button1_Click(object sender, EventArgs e)
        {
            tblQLDonHangPublic p = new tblQLDonHangPublic(
                dateTu.Value,
                dateDen.Value
                );
            DataTable dt = qldh.locNgayLap(p);
            rp_donHang rp = new rp_donHang();
            rp.SetDataSource(dt);
            rp.SetParameterValue("tuNgay", dateTu.Value);
            rp.SetParameterValue("denNgay", dateDen.Value);
            crystalReportViewer1.ReportSource = rp;
        }
    }
}
